<div class="calendarios form">
	<?php echo $this->
		Form->create('Calendario'); ?>
		<fieldset>
			<legend>
				<?php echo __( 'Editar Evaluacion en Calendario Academico'); ?>
			</legend>
			<div class="span12">
				<label>
					Evaluacion
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<?php echo $this->
						Form->text('evaluacion'); ?>
				</p>
			</div>
			<div class="span12">
				<label>
					Fecha desde
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<?php echo $this->
						Form->text('fecha_inicio', array('id' => 'fecha1')); ?>
				</p>
			</div>
			<div class="span12">
				<label>
					Fecha hasta
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<?php echo $this->
						Form->text('fecha_fin', array('id' => 'fecha2')); ?>
				</p>
			</div>
			<div class="span12">
				<label>
					Seleccione la gesti&oacute;n
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<select name="data[Calendario][gestion]" id="chosen_b" data-placeholder="Eliga una gestion..." class="chzn_b" "required"='required'>
						<option value="">
						</option>
						<?php foreach ($gestiones as $gestion): ?>
							<?php if ($this->
								request->data['Calendario']['gestion'] == $gestion['Gestione']['nombre']): ?>
								<option value="<?php echo $gestion['Gestione']['nombre'] ?>" selected="selected">
									<?php echo $gestion[ 'Gestione'][ 'nombre'] ?>
								</option>
								<?php else: ?>
									<option value="<?php echo $gestion['Gestione']['nombre'] ?>">
										<?php echo $gestion[ 'Gestione'][ 'nombre'] ?>
									</option>
									<?php endif; ?>
										<?php endforeach; ?>
					</select>
				</p>
			</div>
			<div class="span12">
				<label>
					Seleccione el nivel
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<select name="data[Calendario][nivel]" id="chosen_a" data-placeholder="Eliga un nivel..." class="chzn_a" "required"='required'>
						<option value="">
						</option>
						<?php $niveles=array( 'Primario', 'Secundario'); foreach ($niveles as $nivel): ?>
							<?php if ($this->
								request->data['Calendario']['nivel'] == $nivel): ?>
								<option value="<?php echo $nivel ?>" selected="selected">
									<?php echo $nivel ?>
								</option>
								<?php else: ?>
									<option value="<?php echo $nivel ?>" selected="selected">
										<?php echo $nivel ?>
									</option>
									<?php endif; ?>
										<?php endforeach; ?>
					</select>
				</p>
			</div>
			<div class="span12">
				<label>
					Seleccione el ciclo
					<span class="f_req">
						*
					</span>
				</label>
				<p>
					<select name="data[Calendario][ciclo_id]" id="chosen_c" data-placeholder="Eliga un ciclo..." class="chzn_b" "required"='required'>
						<option value="">
						</option>
						<?php foreach ($ciclos as $ciclo): ?>
							<?php if ($this->
								request->data['Calendario']['ciclo_id'] == $ciclo['Ciclo']['id']): ?>
								<option value="<?php echo $ciclo['Ciclo']['id'] ?>" selected="selected">
									<?php echo $ciclo[ 'Ciclo'][ 'nombre'] ?>
								</option>
								<?php else: ?>
									<option value="<?php echo $ciclo['Ciclo']['id'] ?>">
										<?php echo $ciclo[ 'Ciclo'][ 'nombre'] ?>
									</option>
									<?php endif; ?>
										<?php endforeach; ?>
					</select>
				</p>
			</div>
		</fieldset>
		<div class="form-actions">
			<button class="btn btn-inverse" type="submit">
				Editar
			</button>
		</div>
</div>
<script type="text/javascript">
	
    $(document).ready(function(){
        $("#fecha1").inputmask("d/m/y",{ "placeholder": "dd/mm/aaaa" });
         $("#fecha2").inputmask("d/m/y",{ "placeholder": "dd/mm/aaaa" });
        
    });

</script>
<!-- sidebar -->
<?php echo $this->
	element('sidebar/calendario'); ?>
	<!-- fin sidebar -->
	<?php //llamamos scripts tablas ?>
		<?php echo $this->
			element('jsformularios'); ?>